package com.csgc.camera.http

import retrofit2.Retrofit
import retrofit2.converter.moshi.MoshiConverterFactory

class ApiService {

    companion object{

        private val builder = Retrofit.Builder()
            .baseUrl(HostConstant.APIHOST)
            .client(OkHttpManager.getInstance().okHttpClient)
            .addConverterFactory(MoshiConverterFactory.create())

        fun <T>createService(clazz: Class<T>):T{
            return builder.build().create(clazz)
        }
    }


}